<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>VideoPlayer</title>
    <link rel="stylesheet" href="./bootstrap/css/bootstrap.min.css" />
    <link rel="stylesheet" href="./font-awesome/css/font-awesome.min.css" />
    <link rel="stylesheet" href="./inspinia/css/animate.css" />
    <link rel="stylesheet" href="./inspinia/css/style.css" />
    <style>
        body{font:14px "Microsoft Yahei",Verdana,Helvetica,Arial,sans-serif,"宋体";}
        body{background:white;}
        #wrap{position:relative;overflow-y:auto;}
        #mainSide{margin:0;height:100%;border-color:#e7eaec;border-width:0 1px;border-style:solid;}
    </style>
</head>
<body>
    <div id="wrap">
        <div id="mainSide">
            <div id="flashContent"></div>
        </div>
    </div>
    <script src="./jquery/1.11.3/jquery.min.js"></script>
    <script src="./swfobject/swfobject.js"></script>
    <script>
        var omeetingDiv = document.getElementById('wrap');
        var resizeOmeetingDiv = function (){
            var h = window.innerHeight;
            $(omeetingDiv).css('height', h + 'px');
        };
        window.addEventListener('resize',function(){
            resizeOmeetingDiv();
        });

        var loadVideoPLayer = function(){
            var swfVersionStr = "20.0.0";
            var xiSwfUrlStr = "./swfobject/expressInstall.swf";
            var flashvars = {};
            flashvars.log = 'all';
            //1-发布视频，2-观看视频
            flashvars.type = '2';
            flashvars.streamUrl = 'rtmp://127.0.0.1:10087/checkapp/iemaker2016';
            flashvars.streamName = 'iemaker-camera';
            var params = {};
            params.quality = "high";
            params.bgcolor = "#ffffff";
            params.allowscriptaccess = "sameDomain";
            params.allowfullscreen = "true";
            var attributes = {};
            attributes.id = "VideoPlayer";
            attributes.name = "VideoPlayer";
            attributes.align = "middle";
            swfobject.embedSWF(
                "./iemaker/VideoPlayer.swf", "flashContent",
                "100%", "100%",
                swfVersionStr, xiSwfUrlStr,
                flashvars, params, attributes
            );
        };

        $(function () {
            resizeOmeetingDiv();
            loadVideoPLayer();
        });
    </script>
</body>
</html>
